.q-if, .q-if:before, .q-if:after, .q-if-label, .q-if-addon, .q-field-icon, .q-field-label, .q-if-control, .q-field-bottom
  transition $input-frame-transition

.q-if
  font-size 16px
  min-height 32px
  margin-top 16px
  margin-bottom 8px
  padding-bottom 8px
  color $primary

  /* Remove browser controller for input type="number" */
  input::-webkit-outer-spin-button,
  input::-webkit-inner-spin-button // @stylint ignore
    -webkit-appearance none

  &:before, &:after
    content ''
    position absolute
    bottom 0
    left 0
    right 0
    background currentColor
  &:before
    height 1px
    color rgba(0, 0, 0, .12)
    transform scaleY(1)
  &:after
    width 0
    height 2px
    color currentColor

  &:hover:before
    color rgba(0, 0, 0, .36)

  .group
    margin -5px

.q-if-focusable
  outline 0
  cursor pointer

.q-if-inner
  min-height 24px !important

.q-if-has-label
  min-height 41px
  .q-if-inner
    min-height 34px !important
    padding-top 15px

.q-if-label
  color rgba(0, 0, 0, .46)
  pointer-events none
  user-select none
  top 15px
  left 0
  right 0
  transform-origin left top 0
  transform scale(1) translate(0, 0)
.q-if-label-above
  transform scale(.75) translate(0, -22px)

.q-if-addon
  pointer-events none
  color rgba(0, 0, 0, .46)
  opacity 0
.q-if-addon-left
  padding-right 8px
.q-if-addon-right
  padding-left 8px
.q-if-addon-visible
  opacity 1

.q-if-control
  cursor pointer
  margin-left 8px
  color rgba(0, 0, 0, .54)
  font-size 24px
  &:hover
    opacity .7
.q-if-control-before
  margin-left 0
  margin-right 8px

.q-if-dark
  &:before, .q-if-label, .q-if-control
    color rgba(255, 255, 255, .7)
  &:hover:before, .q-if-addon
    color rgba(255, 255, 255, .9)

.q-if-focused
  &:after
    width 100%
  .q-if-label
    color currentColor

.q-if-inverted
  min-height 38px
  border-radius 2px
  padding-top 8px
  box-shadow $shadow-1
  &:before, &:after
    display none
  .q-if-control
    color white
  .q-if-control, .q-if-inner
    margin-left 8px
    margin-right 8px

.q-if-error
  &:before, &:after, &:not(.q-if-inverted) .q-if-label, .q-if-addon
    color $negative
  &:hover:before
    color lighten($negative, 26%)

.q-if-disabled
  cursor not-allowed !important
  .q-if-label, .q-if-control
    opacity .6
    cursor not-allowed !important
  &:before
    background-image linear-gradient(90deg, rgba(0, 0, 0, .38) 0, rgba(0, 0, 0, .38) 33%, transparent 0)
    background-color transparent
    background-position bottom
    background-size 3px 1px
    background-repeat repeat-x
